home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Amiga Collections: MegaDisc
/
MegaDisc 42 (1994-11)(MegaDisc Digital Publishing)(AU)(Disk 1 of 2)[WB].zip
/
MegaDisc 42 (1994-11)(MegaDisc Digital Publishing)(AU)(Disk 1 of 2)[WB].adf
/
Programming
/
C_Tutes_9&10
/
Program5.c
< prev
next >
Wrap
C/C++ Source or Header
|
1994-12-12
|
454b
|
21 lines
/*************************************************************
Example using a pointer variable.
**************************************************************/
main()
{
int *my_pointer,dogs;
my_pointer=&dogs; /* my_pointer holds the address of the variable dogs */
dogs=100; /* The integer variable dogs now equals 100 */
printf("\ndogs=%d\n",dogs);
*my_pointer=50; /* The integer variable dogs now equals 50 */
printf("dogs=%d\n\n",dogs);
}